package com.zhiyou100.blog.service;

import com.zhiyou100.blog.dao.impl.MessageDaoImpl;
import com.zhiyou100.blog.entity.Message;

/**
 * @author shkstart
 * @create 2021-10-25 10:26
 */
public class MessageService {
    private MessageDaoImpl dao = new MessageDaoImpl();

    /**
     * 保存留言
     *
     * @param message
     * @return
     */
    public int messageAddition(Message message) {
        return dao.appendMessage(message);
    }

    public int deleteMessageByMid(int mid) {
        return dao.deleteMessageWithId(mid);
    }
}
